<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>用户添加</title>
</head>
<style>
    *{
        margin: 0;
        padding: 0;
    }
    body{
        background-image: linear-gradient(120deg, #a1c4fd 0%, #c2e9fb 100%);
    }
    h2{
        text-align: center;
        color: #ffffff;
        font-family: "Microsoft Yahei", serif;
        letter-spacing:5px;
        margin-top: 20px;
    }
    form{
        margin: auto;
        padding: 10px;
        position: absolute;
        top: 0;left: 0;right: 0;bottom: 0;
        width:500px;
        height: 305px;
        border-radius: 25px;
        background-color:rgba(255, 255, 255, 0.5);
    }
    label{
        letter-spacing:5px;
        font-weight: bold;
    }
    input{
        margin: 2%;
        width: 280px;
    }
    select.custom-arrow {
        position: relative;
        padding: 8px;
        background-color: #fff;
        border: 1px solid #ccc;
    }

    /* 创建箭头 */
    select.custom-arrow::after {
        content: '';
        position: absolute;
        right: 8px;
        top: calc(50% - 2px);
        border-left: 4px solid transparent;
        border-right: 4px solid transparent;
        border-top: 4px solid #000;
        transform: rotate(90deg);
    }
    .status{
        width: 15px;
    }
    .sub{
        margin-top: 10px;
        text-align: center;
    }
    .sub input{
        width: 20%;
        height: 25px;
        border-radius: 15px;
        border: 1px solid #ccc;
    }
    .sub input:hover{
        background-image: linear-gradient(120deg, #d4fc79 0%, #96e6a1 100%);
        border-color: #ccc;
        color: red;
    }
    button{
        float: right;
        margin-right: 10px;
        width: 100px;
        height: 25px;
        border-radius: 15px;
        border: 1px solid #ccc;
    }
    button:hover{
        background-image: linear-gradient(120deg, #d4fc79 0%, #96e6a1 100%);
        border-color: #ccc;
        color: red;
    }
</style>
<body>
<h2>用户添加</h2>
<form action="AddUserServlet" method="post">
    <label for="loginName">登录名称：</label>
    <input type="text" id="loginName" name="loginName" required><br>

    <label for="password"> 登录密码：</label>
    <input type="password" id="password" name="password" required><br>

    <label for="realName">真实姓名：</label>
    <input type="text" id="realName" name="realName" required><br>

    <label for="email">电子邮件：</label>
    <input type="email" id="email" name="email" required><br>

    <label for="userRole">用户角色：&nbsp;</label>
    <select name="userRole" id="userRole" class="custom-arrow">
        <option value="普通用户">普通用户</option>
        <option value="企业用户">企业用户</option>
    </select><br>

    <label>用户状态:&nbsp;</label>
    <input type="radio" id="QY" class="status" name="userStatus" value="启用" checked>
    <label for="QY">启用</label>
    <input type="radio" id="JY" class="status" name="userStatus" value="禁用">
    <label for="JY">禁用</label><br>

    <div class="sub">
        <input type="submit" value="添加用户">
    </div>
    <button type="button" onclick="window.location.href='./index.jsp'">返回首页</button>
</form>
</body>
</html>